import java.util.Scanner;

public class Homework4 {
    public static void main(String[]args){
        Scanner a=new Scanner(System.in);
        System.out.println("购买的长度");
        int num=a.nextInt();
        if (num%3==0){
            System.out.println("需要买"+num/3);
        }
        else if(num%3==1){
            System.out.println("需要买"+(num/3+1));
        }
        else if(num%3==2){
            System.out.println("需要买"+(num/3+1));
        }
    }
}
